<template>
	<svg class="icon svgfont" aria-hidden="true">
		<use :xlink:href="xlinkHref"></use>
	</svg>
</template>

<script>
export default {
  name: 'svgIcon',
  props: {
    type: {
      type: String,
      required: true
    }
  },
  computed: {
    xlinkHref () {
      return `#${this.type}`;
    }
  }
};
</script>

<style scoped lang="stylus">
.icon {
	width 24px
	height 24px
	vertical-align middle
	fill currentColor
	overflow hidden
}
</style>
